<template>
  <div id="details">
    <mavon-editor
      :editable="false"
      :subfield="subfield"
      :boxShadow="false"
      :toolbarsFlag="false"
      v-model="md"
    />
  </div>
</template>

<script>
export default {
  data() {
    return {
      md: "等待加载中",
      subfield: true,
    };
  },
  mounted() {
    this.subfield = false;
    this.axios
      .get("article/details", {
        params: {
          id: this.$route.params.id,
        },
      })
      .then((res) => {
        this.md = res.data;
      });
  },
};
</script>

<style>
#details {
  max-width: 1000px;
  margin: 0 auto;
}
</style>
